Skip to content

GUACAMOLE-2273: Implement FreeRDP AuthenticateEx callback and handle deprecation of Authenticate callback.#670

Open
necouchman wants to merge 1 commit into
apache:staging/1.6.1from
necouchman:jira/2273
Open

GUACAMOLE-2273: Implement FreeRDP AuthenticateEx callback and handle deprecation of Authenticate callback.#670
necouchman wants to merge 1 commit into
apache:staging/1.6.1from
necouchman:jira/2273

Conversation

@necouchman
Copy link
Copy Markdown
Contributor

This pull request implements the AuthenticateEx callback for FreeRDP, and handles versions of FreeRDP where the Authenticate callback has been deprecated and compiled out.

@necouchman necouchman marked this pull request as draft May 4, 2026 01:44
@necouchman necouchman marked this pull request as ready for review May 4, 2026 15:47
@necouchman
Copy link
Copy Markdown
Contributor Author

@mike-jumper @corentin-soriano @sschiffli Anyone do a quick review of this?

Comment thread src/protocols/rdp/rdp.c
* by the connection owner does not support the "required" instruction then the
* connection will fail. This function always returns true. This callback is for
* the AuthenticateEx version, which also provides the "reason" field, indicating
* the type of authentication used to
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the end of the sentence is missing.

Comment thread src/protocols/rdp/rdp.c
Comment on lines +363 to +381
static BOOL rdp_freerdp_authenticate_ex(freerdp* instance, char** username,
char** password, char** domain, rdp_auth_reason reason) {

rdpContext* context = GUAC_RDP_CONTEXT(instance);
guac_client* client = ((rdp_freerdp_context*) context)->client;
guac_rdp_client* rdp_client = (guac_rdp_client*) client->data;
guac_rdp_settings* settings = rdp_client->settings;
char* params[4] = {NULL};
int i = 0;

/* If the client does not support the "required" instruction, warn and
* quit.
*/
if (!guac_client_owner_supports_required(client)) {
guac_client_log(client, GUAC_LOG_WARNING, "Client does not support the "
"\"required\" instruction. No authentication parameters will "
"be requested.");
return TRUE;
}
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Part of the code in rdp_freerdp_authenticate_ex seems to be redundant with rdp_freerdp_authenticate. Perhaps we could extract the common part?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll take a look and see what might make sense. It's a little tricky because the newer function is broken up by the switch statement trying to check for the type of authentication that is being requested, but there are still probably a couple of items that could become static functions and shared by both versions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants